<ion-header>
  <ion-navbar>
    <button ion-button menuToggle>
      <ion-icon name="menu"></ion-icon>
    </button>
    <ion-title>待办</ion-title>
  </ion-navbar>
  <ion-toolbar no-border-top>
    <ion-searchbar color="primary" [(ngModel)]="queryText" (ionInput)="updateSchedule()" placeholder="Search">
    </ion-searchbar>
  </ion-toolbar>
</ion-header>

<ion-content>

  <ion-refresher (ionRefresh)="doRefresh($event)">
    <ion-refresher-content></ion-refresher-content>
  </ion-refresher>

  <ion-list #scheduleList [hidden]="shownSessions === 0">

    <ion-item-group *ngFor="let group of groups" [hidden]="group.hide">

      <ion-item-divider sticky>
        <ion-label>
          {{group.time}}
        </ion-label>
      </ion-item-divider>

      <ion-item-sliding *ngFor="let session of group.sessions" #slidingItem [attr.track]="session.tracks[0] | lowercase" [hidden]="session.hide">

        <button ion-item (click)="goToSessionDetail(session)">
          <h3>{{session.name}}</h3>
          <p>
            {{session.timeStart}} &mdash;
            {{session.timeEnd}}:
            {{session.location}}
          </p>
        </button>

      </ion-item-sliding>

    </ion-item-group>

  </ion-list>

  <ion-list-header [hidden]="shownSessions > 0">
    没有数据
  </ion-list-header>

</ion-content>